home *** CD-ROM | disk | FTP | other *** search
- /*
- * SETPALETTEBUTTONPEN.C
- */
-
- #include "newlook.h"
-
- extern UWORD AddGadget( struct Window *, struct Gadget *, UWORD );
- extern VOID RefreshGList( struct Gadget *, struct Window *, struct Requester *, UWORD );
-
- void SetPaletteButtonPen(w,g,pen)
- struct Window *w;
- struct Gadget *g;
- UBYTE pen;
- {
- struct Border *b;
-
- if(b= (struct Border *)g->UserData)
- {
- USHORT pos= RemoveGadgetSafely(w,g);
- b->FrontPen= pen;
- if(pos!=0xFFFF)
- AddGadget(w,g,pos);
- RefreshGList(g,w,NULL,1L);
- }
- }
-